home *** CD-ROM | disk | FTP | other *** search
/ LOGIC 2000 February / LogicCd--feb.2000-mac-cdr.iso / Apple II / MACDOWN..V.1.0 / MACDOWN.DOC next >
Text File  |  1999-05-30  |  7KB  |  141 lines

  1.    -=[ MacDown 1.0     Copyright 1988 Jason Harper ]=-
  2.  
  3. MacDown is a utility for converting some downloaded Macintosh
  4. files into formats usable on Apple II-series computers.  It
  5. will run on any Apple II that supports ProDOS (in other
  6. words, at least 64K memory), but the screen displays will
  7. probably not be readable on an Apple ][ or ][+, even with a
  8. lower-case adapter.  The program is freeware, meaning that it
  9. is a copyrighted work but I give users the right to freely
  10. distribute it and upload it to computer services.
  11.  
  12. => Why Mac files are a bit difficult to work with.
  13. The Macintosh has a very unusual file system: its files,
  14. instead of being a single sequence of bytes as most
  15. computer's files are, consist of two completely separate
  16. sequences of bytes plus a substantial amount of information
  17. about the file, such as the format of data it contains and
  18. the program that created it.  The two components of a Mac
  19. file are referred to as the 'data fork' and the 'resource
  20. fork': the data fork contains arbitrary data much as other
  21. computer's files do, and the resource fork contains a series
  22. of discrete data items ("resources") such as icons.  A Mac
  23. file may be missing one or both forks: document files tend to
  24. be mainly data, while program files tend to be mainly
  25. resources.  This file arrangement makes it impossible to
  26. simply send a Mac file via modem: there must be some way to
  27. recreate the two forks and the file's directory information.
  28. Early Mac communication programs actually transmitted files
  29. in three pieces which were glued back together at the
  30. receiving end: this works when connected directly to another
  31. Mac, but non-Mac host computer systems generally are not
  32. prepared to handle such files.  So, a standard was developed
  33. to allow all the parts of a Mac file to be appended into a
  34. single data stream, with imbedded information to allow the
  35. original file to be recovered unchanged...
  36.  
  37. => The MacBinary standard.
  38. All current Mac communication programs now automatically
  39. convert transmitted files into MacBinary format, and rebuild
  40. received MacBinary files into an exact copy of the original
  41. file.  The format is quite similar to the Binary II format
  42. used for transfer of files between Apple II computers (which
  43. was based on MacBinary): the transmitted data starts with a
  44. 128-byte header containing the file's directory information
  45. and the length of the two forks, followed by the data fork
  46. (if any) rounded up to a multiple of 128 bytes, followed by
  47. the resource fork (if any) also rounded up.  There are
  48. provisions for tacking on additional information at the end,
  49. but this is seldom (if ever) implemented.  Using MacBinary
  50. files downloaded on an Apple II isn't very difficult: since
  51. most Mac files that are meaningful on other computers contain
  52. only data and no resources, just stripping off the first 128
  53. bytes of the file is sufficient.  This can be done (on files
  54. at most 32K long) from ProDOS Basic with the commands:
  55.   BLOAD mac.file,Ttxt,A$1000
  56.   BSAVE mac.file,Ttxt,A$1080
  57. replacing 'mac.file' and 'txt' with the downloaded file's
  58. actual name and filetype.  The process gets much more
  59. complicated with longer files, and there are other problems
  60. to worry about...
  61.  
  62. => Compressed files.
  63. Mac files tend to be pretty large, so it is a common practice
  64. to apply some sort of compression to them.  There are two
  65. compression methods in current use: PackIt and StuffIt.  Such
  66. files can be easily identified because their names will end
  67. with .PIT or .SIT, respectively.  Another advantage of using
  68. these schemes is that related files (a program and its
  69. documentation, for example) can be packed into one file for
  70. transmission: unlike Binary II, the current implementation of
  71. MacBinary does not allow for multiple files.  StuffIt is the
  72. more recent and more efficient of the two formats:
  73. unfortunately, its author has not seen fit to release enough
  74. information on the format to allow decoders to be developed
  75. for other computers.  PackIt is, however, publicly defined
  76. and MacDown will allow you to decompress such files for use
  77. on an Apple II.
  78.  
  79. => Mac file formats.
  80. Mac files are identified by a 4-character filetype code and a
  81. 4-character creator code: for example, a MacPaint picture has
  82. filetype=PNTG and creator=MPNT.  A MacPaint-format picture
  83. generated by some other program will still have a filetype of
  84. PNTG but will have a different creator.  Some common types:
  85. * PNTG: MacPaint picture.  MacDown will allow you to view
  86. these in HiRes graphics.  If you have an Apple IIgs, see my
  87. SHRConvert utility which will convert these files directly
  88. into several IIgs SuperHiRes formats.
  89. * TEXT: plain text.  Usable with any Apple II program that
  90. deals with text, although some Mac characters (accented
  91. vowels, for example) will not translate properly.
  92. * APPL: application program.  Totally useless on a II.
  93. * PIT : PackIt-format compressed file.
  94. * SIT!: StuffIt-format compressed file: currently unusable.
  95. There are numerous other Mac file formats, such as word
  96. processor documents, that could be used on an Apple II if
  97. someone would write a converter for them (hint hint).
  98.  
  99. => Using MacDown.
  100. MacDown is a ProDOS SYStem program, so you can run it from
  101. Basic by typing "-MACDOWN" (without the quotes, of course).
  102. The program should be fairly easy to use: it is controlled
  103. entirely with the arrow keys (to move the hilighted selection
  104. up or down), Return (to accept the current selection), and
  105. Escape (to go back to the previous menu).  The trickiest part
  106. is the file selector routine used in various parts of the
  107. program: I'd suggest that you put an unimportant disk in a
  108. drive, select 'ProDOS commands' from MacDown's main menu, and
  109. play with it for a while.  Pay close attention to the [set
  110. prefix here] option at the top of each directory listing: you
  111. must use that command at some point to select where you want
  112. converted Mac files to go.  If you're trying to put converted
  113. files on a different disk, both disks must be online at the
  114. same time: disk swapping is not allowed.  All downloaded Mac
  115. files should first be processed with the 'Extract MacBinary'
  116. command.  If the file is PackIt-compressed, you should then
  117. use 'De-compress PackIt' on the extracted file.  You can then
  118. use 'MacPaint => hires' to display any picture files.  For
  119. each file produced by the conversion process, you will be
  120. presented with some info about the file, and given options to
  121. save or not save each fork.  You generally won't want to save
  122. the resource fork of any file, since it is not meaningful on
  123. an Apple II.  Data forks will be saved with the closest
  124. ProDOS equivalent to the original Mac filename: resource
  125. forks will be saved with the same name with '.R' appended.
  126. If a name conflict arises, you will be given options to
  127. cancel, save with a different name ('.N' will be added to the
  128. name), rename the existing file ('.O' will be added), or
  129. delete the existing file.  Note that PackIt files will take a
  130. long time to process, even if you aren't saving either fork.
  131.  
  132. => The end.
  133. Thanks to George Photakis for beta-testing this program.
  134. Please send any questions, comments, bug reports, gripes,
  135. or suggestions (or large sums of money, for that matter) to:
  136.         Jason Harper
  137.         CompuServe: 76703,4222 (preferred)
  138.         GEnie: JR.HARPER
  139.         1480 Michelle Ct. #A
  140.         Colorado Springs, CO 80916
  141.